forum

Home / DeveloperSection / Forums / How to sort tuple list in Erlang?

How to sort tuple list in Erlang?

Anonymous User264411-Mar-2016
I am beginner in Erlang programming. I want to sort according to the second element of each tuple. I already use usort/1 and it works fine but it only works with the first element.
So I think we need to swap each elements and after we do sort operation and after swap it back.
Can you tell me any other easiest solution to sort tuple lists.
Thankyou.

Updated on 14-Mar-2016
I am a content writter !

Can you answer this question?


Answer

1 Answers

Liked By